home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Champak 142
/
Volume 142 Oct 17 2011 - Damaged.iso
/
Games
/
parasite-x.swf
/
scripts
/
frame_8
/
PlaceObject3_27_7
/
CLIPACTIONRECORD onClipEvent(enterFrame).as
Wrap
Text File
|
2011-10-17
|
628b
|
34 lines
onClipEvent(enterFrame){
if(Key.isDown(32))
{
_root.gamepaused = 1;
}
else
{
_root.gamepaused = 0;
}
if(this.hitTest(_root.wall))
{
this._x = -90;
}
if(this.hitTest(_root.wall2))
{
this._x = 620;
}
if(this.hitTest(_root.wall3))
{
this._y = -50;
}
if(this.hitTest(_root.wall4))
{
this._y = 950;
}
if(!this.hitTest(_root.land))
{
}
dist_x = this._x - _root._xmouse;
dist_y = this._y - _root._ymouse;
angle = - Math.atan2(dist_x,dist_y);
this._rotation = angle / 0.017453292519943295;
}